package groupon.common.dao;

import java.io.Serializable;
import java.util.List;

public interface GenericDao<T extends Serializable, ID extends Serializable> {
	
	public T find(Class<T> cls, ID id);

	public void persist(T entity);

	public T merge(T entity);

	public void delete(T entity);

	public List<T> findAll(Class<T> cls);

	public List<T> findInRange(Class<T> cls, int firstResult, int maxResults);

	public long count(Class<T> cls);


}
